package com.iot.ic.service;


import com.iot.ic.common.CustomException;
import com.iot.ic.dao.IllegalResultMapper;
import com.iot.ic.dao.IllegalResultShowMapper;
import com.iot.ic.model.IllegalResult;
import com.iot.ic.model.IllegalResultShow;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * Created by xiuge on 2017/2/20.
 */
@Service
public class IllegalResultShowServiceImpl implements IllegalResultShowService {
	
	@Autowired
	private IllegalResultShowMapper illegalResultShowMapper;

	@Override
	public int addIllegalResultShow(IllegalResultShow illegalResultShow) {
		int falg = illegalResultShowMapper.insert(illegalResultShow);
		return falg;
	}

	@Override
	public List<Map<String, Object>> getIllegalResultShowList(int count, int teamId, String startTime, String endTime) {
		List<Map<String, Object>> dataList = illegalResultShowMapper.selectIllegalResultShowList(count, teamId, startTime, endTime);
		return dataList;
	}

	@Override
	public int deleteIllegalResultShow(int scenesResultId) {
		int result = illegalResultShowMapper.deleteIllegalResultShowByScenesResult(scenesResultId);
		return result;
	}

	@Override
	public int insertIllegalResultShowBatch(List<IllegalResultShow> illegalResultShowList) {
		int result = illegalResultShowMapper.addIllegalResultShowBatch(illegalResultShowList);
		return result;
	}

	
}
